/// File:		SettingsComponent.h
/// Author:		Dennis Norton
/// Date:		03/28/12
/// Purpose:	This class holds the settings for the game and the Wolf Engine.

#ifndef SETTINGSCOMPONENT_H_
#define SETTINGSCOMPONENT_H_

// Fill out any default values here

#define DEFAULT_APP_NAME "### GAME_NAME ###"
#define DEFAULT_CLASS_NAME "Main Window"
#define DEFAULT_WINDOW_WIDTH 1024
#define DEFAULT_WINDOW_HEIGHT 768
#define DEFAULT_VSYNC false
#define DEFAULT_GAMMA 1.0f

// Include this file for HWND
#define WIN32_LEAN_AND_MEAN
#include <Windows.h>

class SettingsComponent
{
	int _WindowWidth, _WindowHeight;
	HWND _MainWinHandle;

	bool _bInitialized, _bVSYNC, _bFullScreen;
	float _Gamma;

public:
	SettingsComponent();
	~SettingsComponent();

	/// Function:	Initialize
	/// Author:		Dennis Norton
	/// Date:		03/28/12
	/// Purpose:		This call initializes all the settings;
	bool Initialize();

	/// Function:	ResetToDefault
	/// Author:		Dennis Norton
	/// Date:		03/28/12
	/// Purpose:		This call resets all the values to the default values.
	void ResetToDefault();

	void GetWindowDimensions(int& Width, int& Height);
	void SetResolution(int Width, int Height);

	inline void SetVSYNC(bool vsync)				{ _bVSYNC = vsync; }
	inline bool GetVSYNC()							{ return _bVSYNC; }
	inline void SetFullScreen(bool fullscreen)		{ _bFullScreen = fullscreen; }
	inline bool GetFullScreen()						{ return _bFullScreen; }
	inline void SetGamma(float gamma)				{ _Gamma = gamma; }
	inline float GetGamma()							{ return _Gamma;}
	inline const char* GetAppName()					{ return DEFAULT_APP_NAME; }
	inline const char* GetClassName()				{ return DEFAULT_CLASS_NAME; }
	inline HWND GetWindowHandle()					{ return _MainWinHandle;	}
	inline void SetWindowHandle(HWND handle)		{ _MainWinHandle = handle; }
};

#endif